package cate.game.role.res.inscription.msg;

import cate.game.GameBody;
import cate.game.client.ClientContext;
import cate.game.client.msg.ClientMsg;
import cate.game.client.msg.MsgConfig;
import cate.game.client.msg.MsgInput;
import cate.game.client.msg.id.MsgIdBInscription;
import easy.java.dev.note.NoteField;

@ClientMsg(title = "铭文页改名 の 请求")
public class PageRenameReq implements MsgInput {

    @NoteField("铭文页id")
    public int id;
    @NoteField("新的铭文页名字")
    public String name;

    @Override
    public void execute(GameBody game, ClientContext cc) {
        cc.getRole().getRes().inscription.setName(id, name);
    }

    @Override
    public MsgConfig conf() {
        return MsgIdBInscription.RENAME_PAGE_REQ;
    }

}
